//
//  WeiXinShareViewController.m
//  myDemo2
//
//  Created by wuxueying on 14-4-30.
//
//

#import "WeiXinShareViewController.h"
#import "WeixinSessionActivity.h"
#import "WeixinTimelineActivity.h"

@interface WeiXinShareViewController ()
@end
@implementation WeiXinShareViewController

- (void)viewDidLoad
{
    [super viewDidLoad];
}

- (IBAction)weixinShare:(id)sender {
    NSArray *activity = @[[[WeixinSessionActivity alloc] init], [[WeixinTimelineActivity alloc] init]];
    UIActivityViewController *activityView = [[UIActivityViewController alloc] initWithActivityItems:@[@"这里是标题", [NSURL URLWithString:@"http://www.google.com"]] applicationActivities:activity];
    activityView.excludedActivityTypes = @[UIActivityTypeAssignToContact, UIActivityTypeCopyToPasteboard, UIActivityTypePrint,UIActivityTypePostToWeibo];
    [self presentViewController:activityView animated:YES completion:nil];
}
@end
